<template>
    <div class="doctor_cell" :class="size ? 'doctor_cell_' + size : ''">
        <div class="image_box">
            <nuxt-link :to="`/certification/material/${info.id}`">
            <li-image :src="info.brandLogo" class="img" v-if="info.brandLogo"  :alt="`${info.materialName}价格表`" />
            <img src="@/assets/images/home/goods.png" class="img"  :alt="`${info.materialName}价格表`" v-else>
        </nuxt-link>
        </div>
        <div class="title"><nuxt-link :to="`/certification/material/${info.id}`">{{ info.materialName }}</nuxt-link></div>
        <div class="post" :title="info.materialOriginPlace">产地：{{ info.materialOriginPlace }}</div>
        <div class="desc" :title="info.belongCompany">所属公司：{{ info.belongCompany }}</div>
    </div>
</template>
<script>
export default {
    name: 'Material',
    props: {
        info: {
            type: Object,
            default: function () {
                return {}
            }
        },
        size: {
            type: String,   // small
            default: ''
        },
        url: {
            type: String,
            default: '/certification/material'
        }
    },
    data() {
        return {

        }
    },
    methods: {
        // 查看详情
        lookDetail() {
            let url = this.url
            let o = this.info
            // let query = this.$route.query;
            // query.id = o.id
            this.$routerPush(url, { id: o.id })
            // this.$router.push({
            //     path: url,
            //     query: { ...query }
            // })
        },
    }
}
</script>
<style lang="less" scoped>
@import './index.less';
</style>